package com.lb.jwitter;
import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import org.hibernate.annotations.ForeignKey;

@Entity
@Table (name="tbl_ctdt_chuyennganh_monhoc")
public class Tbl_CTDT_ChuyenNganh_MonHoc implements Serializable {
   private static final long serialVersionUID = -1989579066723007050L;

   private Long id;
   private Tbl_CTDT_ChuyenNganh chuyenNganhId = null;
   private Integer khoaHoc;
   private Tbl_CTDT_MonHoc monHocId = null;
   private String hocKy;
   private String maLoaiBB;
   private String ghiChu;

   @Id
   @GeneratedValue
   public Long getId() {
	    return id;
   }
   public void setId(Long id) {
	    this.id= id;
   }

   @ManyToOne(fetch=FetchType.EAGER)
   @JoinColumn(name="ChuyenNganhId")
   @ForeignKey(name="FK_tbl_CTDT_ChuyenNganh_tbl_CTDT_ChuyenNganh_MonHoc")
   public Tbl_CTDT_ChuyenNganh getChuyenNganhId() {
	    return chuyenNganhId;
   }
   public void setChuyenNganhId(Tbl_CTDT_ChuyenNganh chuyenNganhId) {
	    this.chuyenNganhId=chuyenNganhId;
   }

   public Integer getKhoaHoc() {
   	return khoaHoc;
   }
   public void setKhoaHoc(Integer khoaHoc) {
   	this.khoaHoc= khoaHoc;
   }

   @ManyToOne(fetch=FetchType.EAGER)
   @JoinColumn(name="MonHocId")
   @ForeignKey(name="FK_tbl_CTDT_MonHoc_tbl_CTDT_ChuyenNganh_MonHoc")
   public Tbl_CTDT_MonHoc getMonHocId() {
	    return monHocId;
   }
   public void setMonHocId(Tbl_CTDT_MonHoc monHocId) {
	    this.monHocId=monHocId;
   }

   public String getHocKy() {
   	return hocKy;
   }
   public void setHocKy(String hocKy) {
   	this.hocKy= hocKy;
   }

   public String getMaLoaiBB() {
   	return maLoaiBB;
   }
   public void setMaLoaiBB(String maLoaiBB) {
   	this.maLoaiBB= maLoaiBB;
   }

   public String getGhiChu() {
   	return ghiChu;
   }
   public void setGhiChu(String ghiChu) {
   	this.ghiChu= ghiChu;
   }
}//endClass 

